<%@ Page Title="" Language="C#" MasterPageFile="~/Employee/MasterPageEmployee.master" AutoEventWireup="true" CodeFile="CreateNewApplication.aspx.cs" Inherits="Employee_CreateNewApplication" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <style type="text/css">
        .style1
        {            font-size: xx-large;
            font-family: Calibri;
            color: #0000FF;
        }
        .style2
        {
            width: 210px;
        }
        .style3
        {
            width: 126px;
        }
        #divCalendar
        {
            display: none;
        }
    </style>
    <script type="text/javascript" src="../Scripts/jquery.js"></script>
    <script type="text/javascript">
        $(function() {
            $('#<%=txtCalendar.ClientID %>').click(function() {
                $('#divCalendar').css('display', 'block');
            });
            $('#<%=txtCalendar.ClientID %>').change(function() {
                $('#divCalendar').css('display', 'none');
            });
        });
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceholder" Runat="Server">
    <div>
        <table style="width:100%;">
            <tr>
                <td  align="center" class="style1" colspan="3">
                    <em>Registered recruitment</em></td>
            </tr>
            <tr>
                <td align="center" class="style3">
                    <asp:Label ID="Label2" runat="server" Text="Vacancy"></asp:Label>
                </td>
                <td class="style2">
                    <asp:DropDownList ID="ddlVacancy" runat="server" Height="29px" Width="216px" 
                        DataSourceID="SqlDataSource1" DataTextField="Title" 
                        DataValueField="VacancyID">
                        <asp:ListItem Selected="True">Please choose vacancy</asp:ListItem>
                    </asp:DropDownList>
                    <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
                        ConnectionString="<%$ ConnectionStrings:connection %>" 
                        SelectCommand="SELECT [VacancyID], [Title] FROM [tb_Vacancy]">
                    </asp:SqlDataSource>
                </td>
                <td>
                    <asp:Label ID="lblErrorVacancy" runat="server" ForeColor="Red"></asp:Label>
                </td>
            </tr>
            <tr>
                <td align="center" class="style3">
                    <asp:Label ID="Label3" runat="server" Text="Full Name"></asp:Label>
                </td>
                <td class="style2">
                    <asp:TextBox ID="txtFullName" runat="server" Width="216px"></asp:TextBox>
                </td>
                <td>
                    <asp:Label ID="lblErrorFullName" runat="server" ForeColor="Red"></asp:Label>
                </td>
            </tr>
            <tr>
                <td align="center" class="style3">
                    <asp:Label ID="Label4" runat="server" Text="Address"></asp:Label>
                </td>
                <td class="style2">
                    <asp:TextBox ID="txtAddress" runat="server" Width="216px"></asp:TextBox>
                </td>
                <td>
                    <asp:Label ID="lblErrorAddress" runat="server" ForeColor="Red"></asp:Label>
                </td>
            </tr>
            <tr>
                <td align="center" class="style3">
                    <asp:Label ID="Label5" runat="server" Text="Phone"></asp:Label>
                </td>
                <td class="style2">
                    <asp:TextBox ID="txtPhone" runat="server" Width="216px"></asp:TextBox>
                </td>
                <td>
                    <asp:Label ID="LblErrorPhone" runat="server" ForeColor="Red"></asp:Label>
                </td>
            </tr>
            <tr>
                <td align="center" class="style3">
                    <asp:Label ID="Label6" runat="server" Text="Date of birth"></asp:Label>
                </td>
                <td class="style2">
                    <asp:TextBox ID="txtCalendar" runat="server"></asp:TextBox>
                    <div id="divCalendar">
                        <asp:Calendar ID="Calendar" runat="server" BackColor="White" 
                        BorderColor="#3366CC" BorderWidth="1px" CellPadding="1" 
                        DayNameFormat="Shortest" Font-Names="Verdana" Font-Size="8pt" 
                        ForeColor="#003399" Height="141px" Width="220px" 
                            onselectionchanged="Calendar_SelectionChanged">
                        <SelectedDayStyle BackColor="#009999" Font-Bold="True" ForeColor="#CCFF99" />
                        <SelectorStyle BackColor="#99CCCC" ForeColor="#336666" />
                        <WeekendDayStyle BackColor="#CCCCFF" />
                        <TodayDayStyle BackColor="#99CCCC" ForeColor="White" />
                        <OtherMonthDayStyle ForeColor="#999999" />
                        <NextPrevStyle Font-Size="8pt" ForeColor="#CCCCFF" />
                        <DayHeaderStyle BackColor="#99CCCC" ForeColor="#336666" Height="1px" />
                        <TitleStyle BackColor="#003399" BorderColor="#3366CC" BorderWidth="1px" 
                            Font-Bold="True" Font-Size="10pt" ForeColor="#CCCCFF" Height="25px" />
                    </asp:Calendar>
                    </div>
                </td>
                <td>
                    <asp:Label ID="lblErrorDateOfBirth" runat="server" ForeColor="Red"></asp:Label>
                </td>
            </tr>
            <tr>
                <td align="center" class="style3">
                    <asp:Label ID="Label7" runat="server" Text="Email"></asp:Label>
                </td>
                <td class="style2">
                    <asp:TextBox ID="txtEmail" runat="server" Width="219px"></asp:TextBox>
                </td>
                <td>
                    <asp:Label ID="lblErrorEmail" runat="server" ForeColor="Red"></asp:Label>
                </td>
            </tr>
            <tr>
                <td align="center" class="style3">
                    &nbsp;</td>
                <td class="style2">
                    <asp:Label ID="lblError" runat="server" ForeColor="Red"></asp:Label>
                </td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td align="center" class="style3">
                    &nbsp;</td>
                <td class="style2">
                    <asp:Button ID="btnSubmit" runat="server" Text="Submit" OnClick="btnSubmit_Click" />
                    <asp:Button ID="btnClear" runat="server" onclick="btnClear_Click" 
                        Text="Clear all" />
                </td>
                <td>
                    &nbsp;</td>
            </tr>
        </table>
    </div>
</asp:Content>

